<?php if ($this->addressArray):?>
            <?php foreach ($this->addressArray as $v):?>
            <div class="ship-adr-item spbg" id="address_<?php echo $v['addressid'];?>">
                <div>
                    <input class="addr-btn1 spbg" type="button" value="SHIP TO THIS ADDRESS" onclick="GGSHOP.address.setAddress(<?php echo $v['addressid'];?>)"/>
                    </div>
                    <div><strong><?php if ($v['name'] != "''") {echo $v['name'];}?></strong></div>
                    <div><?php echo $v['content'];?></div>
                    <div>
                    <?php 
                    for($i=0;$i<count($this->fenleiArray);$i++) {
                    	if ($this->fenleiArray[$i]['flid'] == $v['location_id']) {
                    		echo $this->fenleiArray[$i]['en_flname'] . ' ' . $v['state'] . ' ' . $v['city'];
                    	}
                    }
                    ?>
                    </div>
                    <div>Phone:<?php echo $v['phone'];?> Post Code:<?php echo $v['post_code'];?></div> 
					<div>Email:<?php echo $v['email'];?></div>                   
                    <div class="ship-edit-del">
                    <input class="addr-btn2 spbg" type="button" value="Edit" onclick="GGSHOP.address.showEdit(<?php echo $v['addressid'];?>);"/>&nbsp;&nbsp;<input class="addr-btn2 spbg" type="button" value="Delete" onclick="GGSHOP.address.deleteAddress(<?php echo $v['addressid'];?>);"/>
                    </div>
                </div>
                <div class="ship-adr-item spbg" id="address_edit_<?php echo $v['addressid'];?>" style="display: none;">
                    <div>Full Name: <input type="text" name="name" value="<?php echo $v['name'];?>"/></div>
                    <div>Address: <input type="text" name="address" value="<?php echo $v['content'];?>"/></div>                    
                    <div>COUNTRY: 
                    <select name="state">
                           <option value="0">select your country</option>
                           <option value="599">United States</option>
                           <option value="598">United Kingdom</option>
                           <option value="393">Australia</option>
                           <option value="419">Canada</option>
                           <option value="450">France</option>
                           <option value="456">Germany</option>
                           <option value="459">Greece</option>
                           <option value="563">Spain</option>
                           <option value="578">Sweden</option>
                           <option value="0">------------------------------------</option>
                    	<?php for($i=0;$i<count($this->fenleiArray);$i++):?>
							<option value="<?=$this->fenleiArray[$i]['flid']?>" <?php if ($this->fenleiArray[$i]['flid'] == $v['location_id']) {echo 'selected';}?>><?=$this->fenleiArray[$i]['en_flname']?></option>
						<?php endfor;?>
                        </select>	                       
                    </div>
                    <div>State: <input type="text" name="state1" value="<?php echo $v['state'];?>"/></div>
                    <div>City: <input type="text" name="city" value="<?php echo $v['city'];?>"/> Post Code: <input type="text" name="post_code" value="<?php echo $v['post_code'];?>"/></div>
                    <div>Phone: <input type="text" name="phone" value="<?php echo $v['phone'];?>"/> Email: <input type="text" name="email" value="<?php echo $v['email'];?>" /></div>
                    <div class="ship-edit-del">
                    <input class="addr-btn2 spbg" type="button" value="Confirm" onclick="GGSHOP.address.confirmEdit(<?php echo $v['addressid'];?>);"/>&nbsp;&nbsp;<input class="addr-btn2 spbg" type="button" value="Cancel" onclick="GGSHOP.address.hideEdit(<?php echo $v['addressid'];?>);"/>
                    </div>
                </div>
            <?php endforeach;?>
            <?php else:?>
            0
            <?php endif;?>  